package com.rabbitmq.ChattingRoom.service.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.rabbitmq.ChattingRoom.util.Entity.Room;
import com.rabbitmq.ChattingRoom.util.Entity.UserRoomMapping;
import com.rabbitmq.ChattingRoom.util.common.req.GetMsgReq;
import com.rabbitmq.ChattingRoom.util.common.req.HistoryMSGReq;
import com.rabbitmq.ChattingRoom.util.common.resp.RoomRESP;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

@Mapper
public interface RoomMapper extends BaseMapper<Room> {

    List<RoomRESP> getRoomsByUser(Long userId);

    Integer delRoomByUser(Room record);

    List<HistoryMSGReq> getMsgByCount(GetMsgReq req);

    Long getRoomCreaterByRoomId(Long roomId);

}
